#ifndef SHOWSURVEY_H
#define SHOWSURVEY_H

#include <QWidget>
#include <QSqlDatabase>
#include <QMap>
#include <QDialog>
#include <QTableWidget>
#include <QTableWidgetItem>
#include <QVBoxLayout>
#include <QFormLayout>
#include <QLabel>
#include <QPushButton>
#include <QButtonGroup>
#include <QRadioButton>
#include <QGroupBox>
#include <QSqlQuery>
#include <QSqlError>
#include <QDebug>
#include "database.h"

namespace Ui {
class Showsurvey;
}

class Showsurvey : public QWidget
{
    Q_OBJECT

public:
    explicit Showsurvey(QWidget *parent = nullptr);
    ~Showsurvey();

signals:
    void show_main();

private slots:
    void on_pushButton_clicked();
    void showSubmitDetail(const QString &clientName);


    void on_pushButton_exit_clicked();

private:
    Ui::Showsurvey *ui;
    QSqlDatabase db;
    QMap<QString, QList<int>> clientSubmissions;  // 存储每个用户的提交ID列表
};

#endif // SHOWSURVEY_H
